package com.hc.wego.domain.entity;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import com.hc.wego.bean.BaseEntity;
import java.time.LocalDate;
import java.time.LocalDateTime;
import lombok.AllArgsConstructor;
import lombok.Builder;
import lombok.Getter;
import lombok.NoArgsConstructor;
import lombok.Setter;
import lombok.ToString;
import lombok.experimental.Accessors;

/**
 * 用户
 */
@Getter
@Setter
@Accessors(chain = true)
@ToString
@Builder
@AllArgsConstructor
@NoArgsConstructor
@TableName(value = "tb_user")
public class User extends BaseEntity {
    /**
     * 昵称
     */
    @TableField(value = "nickname")
    private String nickname;

    /**
     * 头像
     */
    @TableField(value = "avatar")
    private String avatar;

    /**
     * 性别
     */
    @TableField(value = "gender")
    private Boolean gender;

    /**
     * 生日
     */
    @TableField(value = "birth")
    private LocalDate birth;

    /**
     * 邮箱
     */
    @TableField(value = "email")
    private String email;

    /**
     * 电话
     */
    @TableField(value = "phone")
    private String phone;

    /**
     * 账户
     */
    @TableField(value = "account")
    private String account;

    /**
     * 加密后的密码
     */
    @TableField(value = "`password`")
    private String password;

    /**
     * 密码盐值
     */
    @TableField(value = "salt")
    private String salt;

    /**
     * 积分
     */
    @TableField(value = "credit")
    private Integer credit;

    /**
     * 用户等级：从低到高1-5
     */
    @TableField(value = "`level`")
    private Integer level;

    /**
     * 显示优先级
     */
    @TableField(value = "priority")
    private Integer priority;

    /**
     * 简介
     */
    @TableField(value = "info")
    private String info;

    /**
     * 是否是管理员
     */
    @TableField(value = "`admin`")
    private Boolean admin;

    /**
     * 删除标识
     */
    @TableField(value = "deleted")
    private Boolean deleted;

    /**
     * 状态
     */
    @TableField(value = "`state`")
    private Integer state;
}